<template>
<div class="text-message">{{text}}</div>
</template>

<script>
export default {
  name: "TextMessageEle",
  props: {
    text: {
      type: String,
      default: "这是一条测试消息"
    }
  }
}
</script>

<style scoped>
.text-message {
  background-color: #f0f0f0;
  border-radius: 7px;
  padding: 10px 12px;
  width: fit-content;
  max-width: 480px;
  line-height: 1.2;
  word-wrap: break-word;
  font-size: 16px;
  margin: 5px 0 5px 0;
}
</style>